package com.iespring.controller.app.search;

import com.fasterxml.jackson.databind.ser.Serializers;
import com.iespring.bean.common.BasePageInfo;
import com.iespring.bean.common.BaseRespVo;
import com.iespring.bean.common.CommonData;
import com.iespring.service.app.search.WxSearchService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * Created with IntelliJ IDEA.
 *
 * @Author:ZhangShuPeng
 * @Date:2023/01/02/13:09
 * @Description:
 */
@RestController
@RequestMapping("wx/search")
public class WxSearchController {

    @Autowired
    WxSearchService wxSearchService;

    @RequestMapping("index")
    public BaseRespVo index() {

        BaseRespVo baseRespVo = wxSearchService.index();
        return baseRespVo;

    }

    @RequestMapping("helper")
    public BaseRespVo helper(BasePageInfo info, String keyword) {

        BaseRespVo baseRespVo = wxSearchService.helper(keyword);
        return baseRespVo;

    }

    @RequestMapping("clearhistory")
    public BaseRespVo clearhistory(BasePageInfo info) {

        BaseRespVo baseRespVo = wxSearchService.clearhistory();
        return baseRespVo;

    }

}
